package designMode.single;

/**
 * @Author 肖地洋
 * @Date 2022/8/12 15:28
 */
public class LazySingle {
    private static LazySingle INTANCE;
    private LazySingle(){
        System.out.println("LazySingle()");
    }
    public static synchronized LazySingle getInstance(){
        if(INTANCE==null){
            INTANCE = new LazySingle();
        }
        return INTANCE;
    }

    public static void main(String[] args) {

    }
}
